<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="../vue.js"></script>
</head>
<body>

<div id="app">

    <component :is="currentView"></component>

</div>

<!-- 在console中输入 app.currentView = 'phoneLogin'  app.currentView = 'emailLogin' -->

<script>
    // 在console中输入 app.currentView = autoLogin
    var autoLogin = {
        template: '<p>自动登录</p>'
    }

    var app = new Vue({
        el: "#app",
        data: {
            currentView: 'userLogin'
        },
        components: {
            userLogin: {
                template: '<p>账号登录</p>'
            },
            phoneLogin: {
                template: '<p>手机登录</p>'
            },
            emailLogin: {
                template: '<p>邮箱登录</p>'
            }
        }
    })

</script>

</body>
</html>